-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Fix mathematically incorrect statements about empty sets in set documentation #11855
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix mathematically incorrect statements about empty sets in set documentation #11855
Conversation
…ation Co-authored-by: eiriktsarpalis <[email protected]>
…er set types Co-authored-by: PranavSenthilnathan <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR corrects mathematically incorrect statements about empty sets in the documentation for various set types' IsProperSubsetOf
and IsProperSupersetOf
methods. The documentation previously claimed that an empty set is a "proper subset" and "proper superset" of any other collection, which violates set theory principles.
- Removes the word "proper" from statements about empty sets in documentation
- Corrects statements to reflect that an empty set is simply a subset of any other collection
- Maintains consistency across all affected set type documentation
Reviewed Changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 4 comments.
File | Description |
---|---|
xml/System.Collections.Immutable/ImmutableSortedSet`1.xml | Fixed empty set statements in IsProperSubsetOf and IsProperSupersetOf documentation |
xml/System.Collections.Generic/SortedSet`1.xml | Fixed empty set statements in IsProperSubsetOf and IsProperSupersetOf documentation |
xml/System.Collections.Generic/ISet`1.xml | Fixed empty set statements in IsProperSubsetOf and IsProperSupersetOf documentation |
xml/System.Collections.Generic/HashSet`1.xml | Fixed empty set statements in IsProperSubsetOf and IsProperSupersetOf documentation |
Problem
The documentation for multiple set types contained mathematically incorrect statements about empty sets:
In
IsProperSupersetOf
methods:In
IsProperSubsetOf
methods:Both statements violate basic set theory principles.
Solution
Corrected all statements to align with mathematical set theory:
Mathematical Background
In set theory:
Change Details
Fixed incorrect statements in the following files:
ImmutableSortedSet`1.xml:
HashSet`1.xml:
SortedSet`1.xml:
ISet`1.xml:
All changes remove the word "proper" from the empty set statements to correctly reflect that an empty set is a subset (not a proper subset or proper superset) of all sets.
Impact
Corrects the mathematical explanations without affecting functionality. The method behavior remains unchanged - the documentation now accurately describes what the methods return.
Fixes #11853
Original prompt
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.